Let the critical section of code complete its job. 使代码的关键部分完成其工作。
For a method that enters a critical section, validate that the method does not return before it is released. 对于进入关键部分的方法,验证该方法未在释放前返回。
Make sure this copying happens inside the critical section by holding a spinlock. 确保这个拷贝是在一个具有自旋锁的临界区中发生的。
If the underlying function is in the middle of a critical section and a signal is generated and handled, this can cause the function to be non-reentrant. 如果底层的函数处于关键部分,并且生成并处理信号,那么这可能会导致函数不可重入。
Critical sections operate on the principle of mutual exclusion ( when a thread is within a critical section, all other threads are excluded from entering). 临界段操作时坚持互斥锁(mutualexclusion)原则(当一个线程处于临界段中时,其他所有线程都不能进入临界段)。
To combat the issue of race conditions, the concept of a critical section was created. 临界段概念是为解决竞态条件问题而产生的。
If a writer has the lock, no reader is allowed to enter the critical section. 如果执行写操作的线程持有此锁,则临界段不能由其他线程读取。
Before entering the critical section, the lock() method of the ReentrantLock object is invoked to try and obtain the lock. 在进入关键部分之前,调用ReentrantLock对象的lock()方法,尝试并获得锁。
If only a reader has the lock, then multiple readers are permitted in the critical section. 如果一个执行读操作的线程持有此锁,那么多个读线程都可以进入临界段。
A critical section is a portion of code that is protected against multiple access. 一个临界段是一段不允许多路访问的受保护的代码。
The ruling paradigm for managing shared state in the Java language and others consists of mutable state protected by locks or other critical section markers. 用Java语言和其他语言管理共享状态的主导范例包括由锁或其他关键节标记保护的可变状态。
Atomic means that the critical section is contained within the API function. 原子意味着临界段被包含在API函数中。
Is your code re-entrant or do you have critical section that must be locked? 您的代码是可重入的,还是设置必须锁定的临界区呢?
This allows us to minimize the amount of work in the critical section which should bias the measurement towards the cost of synchronization. 这样我们可以将临界区内的工作最小化,进而重点测量同步的开销。
Also, the administrator can check for dead applications or those that are reporting they are in a critical section of the program, like long updates to reporting. 同样,管理员可以检查无响应的应用程序,或者那些报告说正处于运行程序临界段,如长时间报表更新。
These methods do not take any locks; they inform the CLR that code is executing in a critical section and aborting the thread could leave shared state inconsistent. 这些方法不使用任何锁;它们通知clr代码正在临界区中执行,中止线程可能会使共享状态不一致。
No other thread can enter the critical section unless it is executing the instructions in the critical section using a different locked object. 其他任何线程都不能进入临界区,除非它使用其他锁定对象执行临界区中的指令。
A critical section object cannot be moved or copied. 一个临界区对象不能移动或复制。
A process wishing to enter a critical section will call P on the relevant semaphore; 一个想进入临界区的进程会调用信号量的P函数;
Methods to mark the beginning and end of a critical section. 方法标记临界区的开头和结尾。
The process is responsible for allocating the memory used by a critical section object, which it can do by declaring a variable of type CRITICAL_SECTION. 这个进程负责分配一个临界区对象使用的内存,它可以通过声明类型的CRITICALSECTION的变量使用的内存。
Then net effect is that we will end up with a longer critical section which may result in other threads stalling and reduced throughput. 这种做法带来的真正效果是我们获得了一个更长的临界区,它可能导致其他线程受到拖延从而降低吞吐量。
The threads of a single process can use a critical section object for mutual-exclusion synchronization. 单个进程的线程可以使用一个互斥同步临界区对象。
Resolution: Related critical section synchronizations were reorganized to remove the race condition. 决议:相关关键路段同步改组,以消除种族的条件。
By strict deduction in mathematics, the mathematical equation of critical section and drawing method is established and elaborated in this paper. 通过分析和数学推导,建立了临界截平面的数学方程,确立了相应的平面作图方法,并对其应用进行了详细叙述。
Data exchange among threads was realized under the protection of critical section. 系统线程间的数据交换在临界区保护模式下实现。
And then, some synchronization techniques, which are semaphore, mutex, event and critical section used in VC++ and synchronized key word used in JAVA, are introduced. 介绍了在VC++中用信号量、互斥体、事件和临界区四种对象实现和在JAVA中用Synchronized关键字实现的同步技术。最后,对改进多线程应用的性能和安全提出了一些策略。
Analysis and research on the critical section of oval cone 椭圆锥临界截平面的分析与研究
Based on the stress analysis on the critical section, this paper presents a simple calculation method. 基于对最不利截面的应力分析,提出了一种简便、快速的悬臂长度计算方法。
In the transplantation, propose a new method to enter and exit critical section. This provides a great convenience to the followed software development. ( 3) Firstly, analyze the basic principle of TCP/ IP stack, according to TCP/ IP document. 在移植时,采用新的进入和退出临界区的方法,为后续的软件开发提供了很大的便利。(3)先根据TCP/IP文档,分析TCP/IP协议栈的基本原理。